/**
 * 
 */
package jpb.test;

import java.util.Arrays;
import java.util.List;


/**
 * Runner class for <tt>JpbApplicationArgumentsTest</tt>, 
 * independent from any external libraries so that tests
 * do not require storing any binaries together with
 * the source code.
 * 
 * @author Dariusz Kordonski
 */
public class JpbApplicationArgumentsTestRunner {

    static final String ARGS_SEPARATOR = ";";
    
    public static void main(String[] args) {
        System.out.println(join(args, ARGS_SEPARATOR));
    }

    private static String join(String[] args, String separator) {
        StringBuilder contents = new StringBuilder(args.length * 8).append(args[0]);
        List<String> argsRest = Arrays.asList(args).subList(1, args.length);
        for (String arg : argsRest) {
            contents.append(separator).append(arg);
        }
        return contents.toString();
    }
    
}
